//
//  NetMannger.m
//  Rac
//
//  Created by 崔博 on 2018/7/5.
//  Copyright © 2018年 崔博. All rights reserved.
//

#import "NetMannger.h"

@implementation NetMannger

+ (RACSignal *)loginWithName:(NSString *)name pwd:(NSString *)pwd
{
    return [RACSignal createSignal:^RACDisposable *(id<RACSubscriber> subscriber) {
        dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(3 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
            [subscriber sendNext:[NSString stringWithFormat:@"User %@, password %@, login!",name, pwd]];
            [subscriber sendCompleted];
        });
        return nil;
    }];
}
@end
